<template>
	<view class="container">
		<uni-steps :options="processList" active-color="#007AFF" :active="active" direction="column"></uni-steps>
	</view>
</template>

<script>
	import { getProcess } from "@/api/dums/caw/caseInfo";
	export default {
		data() {
			return {
				caseId:"",
				processList:[],
				active:0
			}
		},
		onLoad(options) {
			this.caseId = options.caseId;
			this.getProcessList();
		},
		methods: {
			getProcessList(){
				getProcess({caseId:this.caseId}).then(res => {
					console.log(JSON.stringify(res));
					if(res.code == 200){
						this.processList = res.rows.map(item => {
							let desc = "";
							if(item.curr_status_end_date){
								desc = item.curr_status_end_date+"  "
							}
							if(item.executor_opinion){
								desc += item.executor_opinion;
							}
							return {
								title:item.oper_name+"("+item.user_realname+")",
								desc:desc
							}
						})
					}
					
				})
			}
		}
	}
</script>

<style>

</style>
